<%= form_for(@payment) do |f| %>
  <% if @payment.errors.any? %>
    <div id="error_explanation">
      <h2><%= pluralize(@payment.errors.count, "error") %> prohibited this payment from being saved:</h2>

      <ul>
      <% @payment.errors.full_messages.each do |msg| %>
        <li><%= msg %></li>
      <% end %>
      </ul>
    </div>
  <% end %>

  <div class="field">
    <%= f.label :commerce_id %><br />
    <%= f.text_field :commerce_id %>
  </div>
  <div class="field">
    <%= f.label :account %><br />
    <%= f.text_field :account_id %>
  </div>
  <div class="field">
    <%= f.label :amount %><br />
    <%= f.text_field :amount %>
  </div>
    <div class="field">
      <%= f.label :category %><br />
      <%= f.collection_select :category_id, Category.all, :id, :name %>
    </div>
  <div class="actions">
    <%= f.submit %>
  </div>
<% end %>
